﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true"
    CodeBehind="display-block-message.aspx.cs" Inherits="Dala.Samples.display_block_message.display_block_message" %>

<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
    <title>Display Block Message</title>
    <link href="css/default.css" rel="stylesheet" type="text/css" />
    <script src="js/jquery-1.8.2.min.js" type="text/javascript"></script>
    <script src="js/jquery.blockUI.js" type="text/javascript"></script>
    <script type="text/javascript">
        function ShowConfirm(success) {
            if (success) {
                $.blockUI({ message: $('#MessageBox') });
                $(".blockUI").css('cursor', 'default');
                $(".blockMsg").css('width', '30%');
            }
            else {
                $.blockUI({ message: '<h1 style="color:red;">Error</h1>' });
                setTimeout(function () { $.unblockUI(); }, 1000);
                $(".blockUI").css('cursor', 'default');
            }
        }
        function CloseConfirm() {
            $.unblockUI();
        }
    </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <div align="center">
        <asp:Button ID="btnClickMe" runat="server" Text="Click Me" OnClick="btnClickMe_Click" />
    </div>
    <div>
        <div id="MessageBox" style="display: none;">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-hidden="true" onclick="CloseConfirm();">
                    ×</button>
                <h3 id="H1" class="text-success">
                    Thank you! You have been registered</h3>
            </div>
            <div class="modal-body">
                <p>
                    <asp:Literal ID="litSuccessMessage" runat="server"></asp:Literal>
                </p>
            </div>
            <div class="modal-footer">
            </div>
        </div>
    </div>
</asp:Content>